package com.Apo1o.service.Impl;

import com.Apo1o.bean.ext.DiseaseRecordExt;
import com.Apo1o.dao.Ext.DiseaseExtMapper;
import com.Apo1o.service.DiseaseService;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;

/**
 * @Auther: Apo1o.
 * @Date: 2023/11/2-11-02-20:08
 * @Description： com.Apo1o.service.Impl
 */
@Service
@RequiredArgsConstructor
public class DiseaseServiceImpl implements DiseaseService {
    private final DiseaseExtMapper diseaseExtMapper;
    @Override
    public PageInfo<DiseaseRecordExt> findAll(Integer pageNum, Integer pageSize,String dType, String drStatus) {
        PageHelper.startPage(pageNum,pageSize);
        PageInfo<DiseaseRecordExt> pageInfo = new PageInfo<>(diseaseExtMapper.findAll(dType,drStatus));

        return pageInfo;
    }
}
